<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <title>增加商品款型</title>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="../../../component/elementUI/index.css">
  <link rel="stylesheet" href="../../../style/index.css">
</head>

<body>
  <!-- <div id="app" class="content" style="display: flex; width: 300rpx;">
    <span>请选择省份：</span>
    <el-select v-model="Province" placeholder="请选择" @change="handleSelectProvince">
      <el-option
        v-for="(item, index) in options"
        :key="index"
        :label="item.Province"
        :value="item.Province">
      </el-option>
    </el-select>
    <div>
      <el-input v-model="provinceForInput" placeholder="请输入内容" @input="handleInputTruncate"></el-input>
    </div>
  </div> -->
  <div id="app" class="minWidth">
    <el-form :model="form" ref="contract" :rules="rules" inline-message="true" style="width: 100%">
      <div class="table_titel">
        <div class="titel">选择省份</div>
      </div>
      <el-descriptions :column="2" border size="small"> 
        <el-descriptions-item label="省份名称">
          <el-form-item prop="Item_Name">
            <el-select style="width: 100%; " filterable v-model="form.ProvinceNumber" placeholder="请选择" @change="handleSelectProvince">
              <el-option
                v-for="(item, index) in options"
                :key="index"
                :label="item.Province"
                :value="item.ProvinceNumber">
              </el-option>
            </el-select>
          </el-form-item>
        </el-descriptions-item>
        <el-descriptions-item label="省份名称">
          <el-form-item prop="Item_Name">
            <el-input v-model="form.Province_Name" placeholder="请输入内容"></el-input>
          </el-form-item>
        </el-descriptions-item>
        <!-- 第一个图片 -->
        <el-descriptions-item label="省份图片">
          <el-form-item prop="pic">
            <div class="preview" v-show="pic">
              <el-image class="el-upload-list__item-thumbnail" style="width: 148px; height: 148px" :src="pic"
                fit="contain"></el-image>
              <span class="el-upload-list__item-actions">
                <span @click="handlePictureCardPreview(pic)"><i class="el-icon-zoom-in"></i></span>
                <span @click="handleRemove('front')"><i class="el-icon-delete"></i></span>
              </span>
            </div>
            <el-upload v-show="!pic" class="upload-demo" :show-file-list="false" list-type="picture-card" action=""
              accept="image/*" :before-upload="uploadFront">
              <i slot="default" class="el-icon-plus"></i>
              <div class="el-upload__tip" slot="tip">上传正方形图片，且大小不超过120k</div>
            </el-upload>
          </el-form-item>
        </el-descriptions-item>
        <!-- 第二张图片 -->
        <el-descriptions-item label="详情图"> 
          <el-form-item prop="pic2">
            <div class="preview" v-show="pic2">
              <el-image class="el-upload-list__item-thumbnail" style="width: 148px; height: 148px" :src="pic2"
                fit="contain"></el-image>
              <span class="el-upload-list__item-actions">
                <span @click="handlePictureCardPreview(pic2)"><i class="el-icon-zoom-in"></i></span>
                <span @click="handleRemove('front')"><i class="el-icon-delete"></i></span>
              </span>
            </div>
            <el-upload v-show="!pic2" class="upload-demo" :show-file-list="false" list-type="picture-card" action=""
              accept="image/*" :before-upload="uploadFront2">
              <i slot="default" class="el-icon-plus"></i>
              <div class="el-upload__tip" slot="tip">上传正方形图片，且大小不超过120k</div>
            </el-upload>
          </el-form-item>
        </el-descriptions-item>
      </el-descriptions>
      <el-form-item class="form-operation">
        <el-button @click="window.history.back()">返回</el-button>
        <el-button type="primary" :loading="loading" @click="submitForm('contract')">提交</el-button>
      </el-form-item>
    </el-form>
    
  </div>
  <script type="text/javascript" src="../../../utils/jquery-3.6.0.min.js"></script>
  <script type="text/javascript" src="../../../utils/jquery.cookie.js"></script>
  <script type="text/javascript" src="../../../utils/vue.min.js"></script>
  <script type="text/javascript" src="../../../component/elementUI/index.js"></script>
  <script type="text/javascript" src="../../../utils/utils.js"></script>
  <script type="text/javascript" src="../../../utils/ID_Validity.js"></script>
  <script type="text/javascript" src="../../../utils/compressor.js"></script>
  <script type="text/javascript" src="./js/Add.js"></script>
</body>

</html>
